import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';

/**
 * 显示Flutter logo的一个控件  基本用不到
 */
class FlutterLogoDemo extends StatelessWidget{
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: Text("FlutterLogo"),
        centerTitle: true,
      ),
      body: FlutterLogoPageDemo()
    );
  }

}

class FlutterLogoPageDemo extends StatefulWidget {

  @override
  _FlutterLogoPageDemoState createState() => _FlutterLogoPageDemoState();
}

class _FlutterLogoPageDemoState extends State<FlutterLogoPageDemo>{
  @override
  Widget build(BuildContext context) {
    return Container(
        width: MediaQuery.of(context).size.width,
        height: MediaQuery.of(context).size.height,
        child: ListView(
          children: <Widget>[
            FlutterLogo(
                size: 200,//设置大小
                textColor: Colors.blue,//用于在徽标上绘制“Flutter”文本的颜色，如果样式为
                duration: Duration(microseconds: 1),//是否绘制“颤动”文本。默认情况下，仅绘制徽标本身
                style: FlutterLogoStyle.horizontal ,//如果更改样式，颜色或 textColor属性，动画的时间长度
                curve: Curves.bounceIn,//如果样式，颜色或textColor 发生更改，则会生成徽标动画的曲线。
            )
          ],
        ),
    );
  }
}